import { IMessageBase } from "../../Framework/MQ/IMessageBase";
import { MessageManager } from "../../Framework/MQ/MessageManager";
import { SerializeStream } from "../../Framework/Serialize/SerializeStream";
import { SEntityId } from "./SEntityId";
import { SPoint } from "./SPoint";
import { SPublicMiniPlayer } from "./SPublicMiniPlayer";
import { SPlayerItem } from "./SPlayerItem";
type int = number;
//class SDropItem
    
    export  class SDropItem extends IMessageBase
    {
        constructor(arg1: Boolean=false)
        {
            
            super();if (arg1) 
            {
                MessageManager.instance().regist(this);
            }
            return;
        }

        public /* override */ getType(): int
        {
            return this._type;
        }

        public /* override */ clone(): IMessageBase
        {
            return new SDropItem();
        }

        public /* override */ __write(arg1: SerializeStream): void
        {
            this.entityId.__write(arg1);
            arg1.writeInt(this.mapId);
            arg1.writeDate(this.loseDt);
            this.point.__write(arg1);
            arg1.writeInt(this.bossCode);
            this.captain.__write(arg1);
            this.playerItem.__write(arg1);
            return;
        }

        public /* override */ __read(arg1: SerializeStream): void
        {
            this.entityId = new SEntityId();
            this.entityId.__read(arg1);
            this.mapId = arg1.readInt();
            this.loseDt = arg1.readDate();
            this.point = new SPoint();
            this.point.__read(arg1);
            this.bossCode = arg1.readInt();
            this.captain = new SPublicMiniPlayer();
            this.captain.__read(arg1);
            this.playerItem = new SPlayerItem();
            this.playerItem.__read(arg1);
            return;
        }

        public /* const */_type: int=120;

        public /* var */entityId: SEntityId;

        public /* var */mapId: int;

        public /* var */loseDt: Date;

        public /* var */point: SPoint;

        public /* var */bossCode: int;

        public /* var */captain: SPublicMiniPlayer;

        public /* var */playerItem: SPlayerItem;

        public static /* var */_regist: SDropItem;
    }

            SDropItem._regist = new SDropItem(true);
        